package com.bootdo.dataAnalysis.controller;

import com.bootdo.dataAnalysis.domain.DataAnalysisDO;
import com.bootdo.dataAnalysis.service.impl.DataAnalysisImpl;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.*;

import java.util.List;

/**
 * 
 * 
 * @author admin
 * @email 1992lcg@163.com
 * @date 2021-05-09 21:37:16
 */
 
@Controller
@RequestMapping("/dataAnalysis")
public class DataAnalysisController {
	@Autowired
	private DataAnalysisImpl dataAnalysisimpl;
	
	@GetMapping("init")
	/*@RequiresPermissions("work:order:order")*/
	String Order(){
	    return "../static/index.html";
	}
	
	@ResponseBody
	@PostMapping("/list1")
	public List<DataAnalysisDO> list1(){
		List<DataAnalysisDO> dataAnalysisDOList = dataAnalysisimpl.list1();
		return dataAnalysisDOList;
	}
	@ResponseBody
	@PostMapping("/list2")
	public List<DataAnalysisDO> list2(){
		List<DataAnalysisDO> dataAnalysisDOList = dataAnalysisimpl.list2();
		return dataAnalysisDOList;
	}
	@ResponseBody
	@PostMapping("/list3")
	public List<DataAnalysisDO> list3(){
		List<DataAnalysisDO> dataAnalysisDOList = dataAnalysisimpl.list3();
		return dataAnalysisDOList;
	}
	@ResponseBody
	@PostMapping("/list4")
	public List<DataAnalysisDO> list4(){
		List<DataAnalysisDO> dataAnalysisDOList = dataAnalysisimpl.list4();
		return dataAnalysisDOList;
	}
	@ResponseBody
	@PostMapping("/list5")
	public List<DataAnalysisDO> list5(){
		List<DataAnalysisDO> dataAnalysisDOList = dataAnalysisimpl.list5();
		return dataAnalysisDOList;
	}
	@ResponseBody
	@PostMapping("/list6")
	public List<DataAnalysisDO> list6(){
		List<DataAnalysisDO> dataAnalysisDOList = dataAnalysisimpl.list6();
		return dataAnalysisDOList;
	}
	@ResponseBody
	@PostMapping("/countcar")
	public int countcar(){
		int count = dataAnalysisimpl.countcar();
		return count;
	}
	@ResponseBody
	@PostMapping("/countuser")
	public int countuser(){
		int count = dataAnalysisimpl.countuser();
		return count;
	}
}
